using System;
using System.Text;
using System.Collections.Generic;
using Sce.PlayStation.HighLevel.UI;

namespace VitaReaderLibPS
{

	public class InputBox : MessageBox
	{	
		//Label UILbInput;
		EditableText UIEdInput;
		
		public InputBox(String title,String message,ReaderScene scene,OnOKDelegate deleg)
			:base(title,message,scene,MessageDialogStyle.OkCancel,deleg,null)
		{
			UIEdInput = new EditableText();
			
			
			mDelegateTarget = UIEdInput;
			this.Result = DialogResult.Cancel;
			
			const float INPUT_HEIGHT = 40;
			const float INPUT_PADDING = 10;
			
			UIEdInput.SetSize(this.Width-INPUT_PADDING*2,INPUT_HEIGHT);
			UIEdInput.SetPosition( INPUT_PADDING, this.Height/2-UIEdInput.Height/2);
			this.AddChildLast(UIEdInput);
		}
		
		public void SetDefaultInput(String s)
		{
			UIEdInput.Text = s;
		}
	}
}